import { requestApi } from '@/utils/request';
import { option } from './optionParam';


// export const mergeFile = data =>
//   request({
//     url: '/bigFile/mergeFile',
//     method: 'post',
//     data: JSON.stringify(data),
//   });

  export const mergeFile = data => {
    option.isJson = true
    option.data = JSON.stringify(data)
    option.method = 'post'
    option.url = '/bigFile/mergeFile'
    return requestApi(option)
  }

export const selectFileList = query => {
    option.isJson = true
    option.data = query
    option.method = 'post'
    option.url = '/uploader/selectFileList'
    return requestApi(option)
};

export const deleteFile = data => {
  option.isJson = true
  option.data = JSON.stringify(data)
  option.method = 'post'
  option.url = '/uploader/deleteFile'
  return requestApi(option)
}

export const downloadFile = query => {
  option.isJson = true
  option.data = query
  option.method = 'get'
  option.url = '/uploader/download'
  return requestApi(option)
};

